package com.itheima06;

public class Test {
    public static void main(String[] args) {
        method2(new JieKou() {
            @Override
            public void method1() {
                System.out.println("匿名内部类");
            }
        });
        method2(() ->{
            System.out.println("匿名内部类");
        }
    );
    }

    public static void method2(JieKou kou) {
        kou.method1();
    }
}
